﻿@model ABCTile.Models.Test
@{
    Layout = "~/Views/Shared/_Layout.cshtml";
}

@Html.ActionLink("Example1", "ExampleForRazorView1", "Test") |
@Html.ActionLink("Example2", "ExampleForRazorView2", "Test")

<table>
    <tr>
        <th>HTML Element</th>
        <th>Basic Input HTML Helpers</th>
        <th>Strongly Typed Input HTML Helpers</th>
    </tr>
    <tr>
        <th>Checkbox</th>
        <td>@Html.CheckBox("myCheckbox", false)</td>
        <td>@Html.CheckBoxFor(x => x.IsApproved1)</td>
    </tr>
    <tr>
        <th>Hidden Field</th>
        <td>@Html.Hidden("myHidden", "val")</td>
        <td>@Html.HiddenFor(x => x.String1)</td>
    </tr>
    <tr>
        <th>Radio Button</th>
        <td>@Html.RadioButton("myRadioButton", "val", true)</td>
        <td>@Html.RadioButtonFor(x => x.IsApproved2, "val", true)</td>
    </tr>
    <tr>
        <th>Password</th>
        <td>@Html.Password("myPassword", "val")</td>
        <td>@Html.PasswordFor(x => x.Password)</td>
    </tr>
    <tr>
        <th>Text area</th>
        <td>@Html.TextArea("myTextarea", "val", 5, 20, null)</td>
        <td>@Html.TextAreaFor(x => x.String2, 5, 20, new {})</td>
    </tr>
    <tr>
        <th>Text box</th>
        <td>@Html.TextBox("myTextbox", "val")</td>
        <td>@Html.TextBoxFor(x => x.String3)</td>
    </tr>
    <tr>
        <th>Drop-down list</th>
        <td>@Html.DropDownList("myList", new SelectList(new []{"A", "B"}), "Choose")</td>
        <td>@Html.DropDownListFor(x => x.List1, new SelectList(new[]{"A", "B"}, "Choose"))</td>
    </tr>
    <tr>
        <th>Multiple-select list</th>
        <td>@Html.ListBox("myList", new MultiSelectList(new [] {"A", "B"}))</td>
        <td>@Html.ListBoxFor(x => x.List2, new MultiSelectList(new[] { "A", "B" }))</td>
    </tr>
    <tr>
        <th>Link</th>
        <td>@Html.ActionLink("myLink", "ExampleForRazorView2", "Test")</td>
        <td></td>
    </tr>
    <tr>
        <th>Form and Submit button</th>
        <td> Route to the same action name
            @using (Html.BeginForm())
            { 
                <input type = "submit" value = "OK" />
            }
        </td>
        <td> Route to the specified action name
            @using (Html.BeginForm("Index", "Home"))
            { 
                <input type = "submit" value = "OK" />
            }
        </td>
    </tr>
</table>